package com.managermype.dao.interfaces;

import java.util.List;

import org.springframework.dao.DataAccessException;

import com.managermype.domain.Enterprise;

/**
 * 
 * @author juandiego
 *
 */
public interface EnterpriseDao {

	/**
	 * 
	 * @param name
	 * @return
	 * @throws DataAccessException
	 */
	public List<Enterprise> listByName(String name) throws DataAccessException;

	/**
	 * 
	 * @return
	 * @throws DataAccessException
	 */
	public List<Enterprise> listAll() throws DataAccessException;

	/**
	 * 
	 * @param ruc
	 * @return
	 * @throws DataAccessException
	 */
	public Enterprise getByRuc(String ruc) throws DataAccessException;

	/**
	 * 
	 * @param idEnterprise
	 * @return
	 * @throws DataAccessException
	 */
	public Enterprise getById(Integer idEnterprise) throws DataAccessException;

	/**
	 * 
	 * @return
	 * @throws DataAccessException
	 */
	public Integer countAllRegistred() throws DataAccessException;

	/**
	 * 
	 * @param enterprise
	 * @return
	 * @throws DataAccessException
	 */
	public Enterprise insert(Enterprise enterprise) throws DataAccessException;

	/**
	 * 
	 * @param enterprise
	 * @throws DataAccessException
	 */
	public void update(Enterprise enterprise) throws DataAccessException;
}
